package api.sea;

import conf.Url;
import util.HttpClientUtils;
import util.ResponseData;

import java.io.IOException;
import java.net.URISyntaxException;
import java.util.HashMap;
import java.util.Map;

public class ArrivalPortApi {
    private final String arrival_port_url;

    {
        arrival_port_url = Url.Base_Url+ "consumer/lgsWtd5/process";
    }

    public ResponseData arrival_port(String id,String systemNumber,String actualArrivalDate,String clearanceState,String clearanceBankName,
                                     String clearanceDate,int state,boolean isSignIn,String arrivePortStatus) throws IOException, URISyntaxException {
        Map<String,Object> data=new HashMap<>();
        data.put("id",id);
        data.put("systemNumber",systemNumber);
        data.put("actualArrivalDate",actualArrivalDate);
        data.put("clearanceState",clearanceState);
        data.put("clearanceBankName",clearanceBankName);
        data.put("clearanceDate",clearanceDate);
        data.put("state",state);
        data.put("isSignIn",isSignIn);
        data.put("arrivePortStatus",arrivePortStatus);
        return HttpClientUtils.post_json(arrival_port_url,data);
    }
}
